import React, { PureComponent } from 'react';

// import Home from '../home';
import Home from '../home copy';

import Profile from '../profile';
                // 2.定义主题 共享样式
import styled, { ThemeProvider } from 'styled-components'

//1.样式继承
const MyBtn = styled.button`
  padding: 15px 25px;
  border-color: brown;
`
const MySuccessBtn = styled(MyBtn)` 
  background-color: green;
  margin-left: 15px;
`

export default class App extends PureComponent {
  render() {
    return (
      <ThemeProvider theme={{themeColor: 'yellow', themeFontSize: '40px'}}>
        <MyBtn>普通的按钮</MyBtn>
        <MySuccessBtn>继承样式按钮</MySuccessBtn>
        <h2>我是App的title</h2>
        <hr />
        
        { false && <Home/>}
        <hr />
        { false && <Profile/>}
      </ThemeProvider>
    )
  }
}
